package com.share.demo.thread;

/**
 * created by caifan 2018/10/08
 */
public class MyTask implements Runnable {

    private Integer num;
    public MyTask(Integer num) {
        this.num = num;
    }

    @Override
    public void run() {
        System.out.println(Thread.currentThread().getName() + "::" + num);
        try {
            Thread.currentThread().sleep(3000);
        } catch (InterruptedException e) {
            e.printStackTrace();
        }
        System.out.println(Thread.currentThread().getName() + "&" + num + ":执行完毕");
    }
}
